p
  = link_to '新增', new_building_path, class: "btn btn-info btn-xs"
= paginate @buildings
table.table.table-inverse.table-striped.table-bordered.table-hover
  thead
    tr
      th 楼栋号
      th 小区名
      th 楼栋管理员
      th 小区管理员
  tbody
    - @buildings.each do |building|
      tr
        td = building.code
        td = building.village.name
        td = building.editor.name
        td = building.village.editors.with_role(:estate).first.name
